package com.diankangwo.factory.service.impl;

import com.diankangwo.factory.dao.TdOrderMapper;
import com.diankangwo.factory.entity.TdOrder;
import com.diankangwo.factory.service.TdOrderService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import java.util.List;
import java.util.Map;

@Service("TdOrderService")
public class TdOrderServiceImpl implements TdOrderService {
    @Autowired
    TdOrderMapper tdOrderMapper;

    @Override
    @Transactional
    public int deleteByPrimaryKey(Integer id) {
        return tdOrderMapper.deleteByPrimaryKey(id);
    }

    @Override
    @Transactional
    public int insert(TdOrder record) {
        return tdOrderMapper.insert(record);
    }

    @Override
    @Transactional
    public int insertSelective(TdOrder record) {
        return tdOrderMapper.insertSelective(record);
    }

    @Override
    public TdOrder selectByPrimaryKey(Integer id) {
        return tdOrderMapper.selectByPrimaryKey(id);
    }

    @Override
    @Transactional
    public int updateByPrimaryKeySelective(TdOrder record) {
        return tdOrderMapper.updateByPrimaryKeySelective(record);
    }

    @Override
    @Transactional
    public int updateByPrimaryKey(TdOrder record) {
        return tdOrderMapper.updateByPrimaryKey(record);
    }

    @Override
    public List<TdOrder> queryList(Map<String, Object> map) {
        return tdOrderMapper.queryList(map);
    }

    @Override
    public int queryTotal(Map<String, Object> map) {
        return tdOrderMapper.queryTotal(map);
    }

    @Override
    public List<TdOrder> queryByDay(String startTime, String endTime) {
        return tdOrderMapper.queryByDay(startTime,endTime);
    }

    @Override
    public List<TdOrder> queryByStatus(String orderStatus) {
        return tdOrderMapper.queryByStatus(orderStatus);
    }

    @Override
    public List<TdOrder> queryByUid(String uid) {
        return tdOrderMapper.queryByUid(uid);
    }

    @Override
    public TdOrder queryByOrderNo(String orderNo) {
        return tdOrderMapper.queryByOrderNo(orderNo);
    }
}
